//
// Created by uranus on 2021/7/13.
//
#include<iostream>
#include<string>

using namespace std;

void moveDisks(int n,string source,string dest,string temp){
    if(n>0){
        // move n-1 disks from source to temp
        //using dest as th temporary peg
        moveDisks(n-1,source,temp,dest);
        // Move a disk from source to dest
        cout<<"Move a disk from "<<source<<" to "<<dest<<endl;
        //Move n-1 disks from temp to dest
        //using source as the temporary peg
        moveDisks(n-1,temp,dest,source);
    }
}